package leecode

type ListNode83 struct {
	Var  int
	Next *ListNode83
}

func deleteDuplicates(head *ListNode83) *ListNode83 {
	if head == nil {
		return head
	}
	temp := head
	for temp.Next != nil {
		if temp.Next.Var == temp.Var {
			temp.Next = temp.Next.Next
		} else {
			temp = temp.Next
		}
	}
	return head
}
